package com.example.curriculum.service;

import com.example.curriculum.pojo.OutBound;
import com.example.curriculum.repository.OutBoundRepository;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

@Service
public class OutBoundService implements IOutBoundService{
    @Resource
    private OutBoundRepository repo;

    @Override
    public OutBound add(OutBound outbound) {
        repo.save(outbound);
        return outbound;
    }

    @Override
    public OutBound select(String bill_id) {
        return repo.findById(bill_id);
    }

    @Override
    public OutBound update(OutBound outbound) {
        repo.update(outbound);
        return outbound;
    }

    @Override
    public void delete(String bill_id) {
        repo.deleteById(bill_id);
    }
}
